(function ($, root) {
    function createDom(src) {
        var img = new Image();
        img.src = src;
        console.log(src)
        img.onload = function () {
            $('.img-box img').attr('src', src);
            root.blurImg(img, $('body'))
        }
    }

    function info(data) {
        console.log(data)
        var str = '<div class="song-name">' + data.album + '</div>\
        <div class="singer-name">' + data.singer + '</di>\
                        <div class="album-name">' + data.song + '</div>\
                 </div>'
        $('.song-info').html(str)
    }

    function like(like) {
        if (like) {
            $('.like').addClass('likeing');
        } else {
            $('.like').removeClass('likeing')
        }
    }  
    function list(data){
       var list = Object.getOwnPropertyNames(data);
       console.log(list)
    }
    root.render = function (data) {
        createDom(data.image);
        info(data);
        like(data.isLike);

    }

})(window.Zepto, window.player || (window.player = {}))